package oop.data;

import java.sql.SQLException;

import oop.db.dao.TopicDAO;

public class TopicConstraint extends CountConstraint {

	private long topicId;

	public TopicConstraint(long sectionStructureId, long topicId, int count) {
		super(sectionStructureId, count);
		this.topicId = topicId;
	}

	public Topic getTopic() throws SQLException {
		return TopicDAO.fetchById(topicId);
	}
	
}
